package com.qf.smsplatfrom.mapper;

import com.qf.smsplatfrom.pojo.DirtyWord;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface DirtyWordMapper {
    @Select("select * from t_dirtyword where id = #{id}")
    DirtyWord  findDirtyWordById(Long id);
    @Insert("insert into t_dirtyword(dirtyword,owntype,creater) values(#{dirtyword},#{owntype},#{creater})")
    int addDirty(DirtyWord dirtyWord);
    @Select("select * from t_dirtyword")
    List<DirtyWord> showAll();

    int updateDirtyById(DirtyWord dirtyWord);
    int deleteDirtyByIds(@Param("ids")List<Integer> ids);
    int deleteNoDirtyByIds(List<Integer> ids,@Param("creater") Long creater);

}
